# Contributor: dai9ah <dai9ah@protonmail.com>
# Maintainer: Celeste <cielesti@protonmail.com>
pkgname=bfs
pkgver=3.2
pkgrel=0
pkgdesc="Breadth-first variant of the UNIX find command"
url="https://github.com/tavianator/bfs"
arch="all"
license="0BSD"
makedepends="
	acl-dev
	attr-dev
	libcap-dev
	liburing-dev
	linux-headers
	oniguruma-dev
	"
checkdepends="bash acl coreutils"
subpackages="$pkgname-doc
	$pkgname-bash-completion
	$pkgname-zsh-completion
	$pkgname-fish-completion
	"
source="bfs-$pkgver.tar.gz::https://github.com/tavianator/bfs/archive/$pkgver.tar.gz"

build() {
	./configure \
		--enable-release \
		--enable-libacl \
		--enable-libcap \
		--enable-liburing \
		--enable-oniguruma
	make
}

check() {
	TEST_FLAGS="--verbose" make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
2881a37b65d8015853a658a4f759a5213ea433a726ee9952b82bd2d6c682f92e7d014eaa7ec8f1d127b3c25b5d3b04e3b24ae61ec2549212a7a4f9335f91bf8b  bfs-3.2.tar.gz
"
